import React, { useState, useEffect } from 'react';

export default function App() {
  const [count, setCount] = useState<number>(0);

  useEffect(() => {
    document.title = `已点击${count}次...`;
  }, [count]);

  return (
    <div className="App">
      <div>This is the indics page.</div>
      <div>{count}</div>
      <div>
        <button type="button" onClick={() => setCount(count + 1)}>
          点击+1
        </button>
      </div>
    </div>
  );
}
